﻿using System;
using ASPNETVN.PORTAL.Components.UI;
using WEATHER.Components;

namespace ThoiTiet.Modules.ProvinceWeather.Controls
{
    public partial class ProvinceWeather : ModulePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (IsPostBack == false)
            {
                string provinceCode = Request["provinceid"] ?? "/21/92";
                DetailPage.InnerHtml = Province.GetWeatherDetailOnline(provinceCode);
                ddlProvinces.SelectedValue = provinceCode;
            }
        }

        protected void butView_Click(object sender, EventArgs e)
        {
            DetailPage.InnerHtml = Province.GetWeatherDetailOnline(ddlProvinces.SelectedValue);
        }
    }
}